﻿@using KMF.WebUI.Areas.KMFadmin.CustomHelpers
@using KMF.WebUI.Areas.KMFadmin.Models
@model KMF.Common.PageDto
@{
    ViewBag.Title = "EditPage";
    Layout = "~/Areas/KMFadmin/Views/Shared/_layout.cshtml";
}

<nav>
    <div id="jCrumbs" class="breadCrumb module">
        <ul>
            <li><a href="@Url.Action("Index", "AdminHome")"><i class="bootstrap icon-home"></i></a></li>
            <li><a href="@Url.Action("Index", "AdminBanner")">Banner</a> </li>
            <li><a href="@Url.Action("PageList", "AdminBanner")">Danh sách trang</a></li>
            <li><a href="javascript:void(0);">Chỉnh sửa trang</a></li>
        </ul>
    </div>
</nav>

<div class="toolBox">
    @Html.ToolBox(new List<object> { new Add { ClassCss = "Edit", ActionName = "Javascript:void(0)" }
            , new Back { ClassCss = "Back", ActionName = @Url.Action("PageList","AdminBanner") }})
</div>

@using (Html.BeginForm("EditPage", "AdminBanner", FormMethod.Post))
{
    <div class="box-Info">
        <div class="Info-header">
            <span>Chỉnh sửa trang</span>
        </div>

        <div class="Info-body ib-infopro">
            <div>@Html.ValidationMessage("ErrorSummary")</div>
            @Html.HiddenFor(m => m.PageId)
            @Html.HiddenFor(m => m.CreateDate)
            <table cellpadding="0" cellspacing="0" width="100%" border="0" class="table-info">
                <tr>
                    <td class="tInfoLeft">Tên sản phẩm
                    </td>
                    <td class="tInfoRight">
                        @Html.TextBoxFor(m => m.Name)
                        @Html.ValidationMessageFor(m => m.Name)
                    </td>
                </tr>
                <tr>
                    <td class="tInfoLeft">Thứ tự
                    </td>
                    <td class="tInfoRight">
                        @Html.TextBoxFor(m => m.Order)
                        @Html.ValidationMessageFor(m => m.Order)
                    </td>
                </tr>
            </table>
        </div>
    </div>
}

@section scripts
{
    <script src="~/Areas/KMFadmin/Scripts/jquery.validate.min.js"></script>
    <script src="~/Areas/KMFadmin/Scripts/jquery.validate.unobtrusive.min.js"></script>
    <script>
        SubmitFormUseToolBox($('ul li.Edit a'), $('form'));
    </script>
}

